<?php
	session_start();
	include ("../includes/conn.php");

	import_request_variables("gp","v_");
	$csn=$v_csn;
	$ssn=$v_ssn;
	$dsn=$v_dsn;
	$catno=$v_catno;
	
	if (!isset($_SESSION['id'])){
		$_SESSION['id'] = md5(rand());
	}
	
	//add product to shopping cart
	if (isset($addsign) && $addsign == '1'){
		require_once("../includes/cart.php");
	}
	
	//update shopping cart when amount and/or promo code change
	if (isset($button) && $button == 'Update'){
		if ($qtychg <> ''){
			require_once("../includes/cart-upd.php");
		}
	}
	
	// delete selected product in shopping cart
	if (isset($button2) && $button2 == 'Remove'){
		require_once ('../includes/cart-delete.php');
	}
	
	//empty all products in shopping cart
	if (isset($button5) && $button5 == 'Clear All' ){
		require_once ('../includes/cart-empty.php');
	}
	
	//check out shopping cart for payment
	if (isset($button3) && $button3 == 'Check Out' ){
		echo "<script language=javascript>location.href='../cart-checkout.php';</script>";
		exit;
	}
	
	if (!isset($cart)){
		$cart = 0;
	}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<?php include ("../includes/title.php");?>
<link href="../style/abmnew.css" rel="stylesheet" type="text/css" />
<link href="../style/mirna.css" rel="stylesheet" type="text/css" />
<style type="text/css">
#submenu {
	background:url(../SecondAntibody/images/banner-stemcellantibody.jpg) right top;
	background-repeat:no-repeat;
}
</style>
</head>
<body>
<?php include ("../includes/header.php");?>
<div id="content">
  <?php include ("../includes/logosearch.php");?>
  <div id='container'>
    <div id='leftmenu'>
      <?php
	  	include ("../includes/leftMenu.php");
	  ?>
    </div>
    <div id='rightcontent'>
      <div id='submenu'>
        <div id='subtitle'>Viral Expression</div>
      </div>
      <div id='prod-detail'>
        <div id='order'> &nbsp; To order products, check the corresponding boxes on the right and then click 'Add to Cart'.
          <form id="form2" name="form2" method="post" action="#cart">
          <div id='exp-list'>
            <?php 
				  echo"<table id='exp-table' width='100%' border='0' cellspacing='0' cellpadding='0' >
						<tr align='center'>
							<th width='340px' align='left'>Product</th>
							<th width='50px'>Size</th>
							<th width='50px'>Cat. No.</th>
							<th align='right' width='40px'>Price</th>
							<th width='40px'><img src='../img/icons/shopping_cart.png' width='17' height='17' /></th>
						</tr>";
						$prod = "select * from prodviralexp where catNo like '$catno'";
						$prod_res = mysql_query($prod,$db);
						$prod_rows = mysql_num_rows ($prod_res);
						if ($prod_rows > 0){
							while($prod_r = mysql_fetch_array($prod_res)){
								$prodname = $prod_r['pname'];
								$catno = $prod_r['catNo'];
								$price = ROUND($prod_r['price'],0);
								$quant = $prod_r['quantity'];
								echo"<tr>";
								switch ($catno){
									case "A001":
									case "A002":
									case "A003":
									case "A004":
									case "A005":
									case "A006":
									case "A007":
									case "A014":
									case "A013":
									case "A100":
									case "A110":
									case "A120":
									case "C094":
									case "A097":
									case "A098":
									case "A099":
										$links = "/CMV-Adenovirus-Expression-Systems.html";
										break;
										
									case "A001":
									case "A008":
									case "A020":
									case "A009":
									case "A004":
									case "A005":
									case "A006":
									case "A007":
									case "A014":
									case "A013":
									case "A200":
									case "A240":
									case "A210":
									case "A220":
									case "A250":
									case "A098":
									case "A099":
										$links = "/His-HA-Adenovirus-Expression-System.html";
										break;
										
									case "A001":
									case "A010":
									case "A004":
									case "A005":
									case "A006":
									case "A007":
									case "A014":
									case "A013":
									case "A300":
									case "A310":
									case "A097":
									case "A098":
									case "A099":
										$links = "/Vira-Power-Adenoviral-Expression-Systems.html";
										break;
										
									case "A001":
									case "A012":
									case "A004":
									case "A005":
									case "A006":
									case "A007":
									case "A014":
									case "A013":
									case "A400":
									case "A410":
									case "A097":
									case "A098":
									case "A099":
										$links = "/siRNA-Adenovirus-RNAi-Adenovirus-miRNA-Adenovirus.html";
										break;
										
									case "A001":
									case "A015":
									case "A004":
									case "A005":
									case "A006":
									case "A007":
									case "A014":
									case "A013":
									case "A500":
									case "A510":
									case "A097":
									case "A098":
									case "A099":
										$links = "/Luciferase-Adenoviral-Vector-System.html";
										break;
										
									case "A001":
									case "A021":
									case "A004":
									case "A005":
									case "A006":
									case "A007":
									case "A014":
									case "A013":
									case "A022":
									case "A800":
									case "A810":
									case "A097":
									case "A098":
									case "A099":
										$links = "/RFP-mKate-Expression-Vector.html";
										break;//adenoviral expression systems 
										
									case "A902":
									case "A905":
									case "A910":
										$links = "/Adenovirus-Purification.html";
										break;
									case "G130":
										$links = "/Adenovirus-Storage.html";
										break;
									case "A1-20T":
										$links = "Adenovirus-Titration.html";
										break;
									case "G097":
										$links = "Hexon-Antibody.html";
										break;//adenoviral related kits
										
									case "LV009":
									case "LV003":
									case "LV010":
									case "G074":
									case "LV011-a":
									case "LV100":
									case "LV110":
									case "LV098":
									case "LV099":
										$links = "/His-Tag-Lentivirus-Expression-System.html";
										break;
										
									case "LV005":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV200":
									case "LV210":
									case "LV098":
									case "LV099":
										$links = "/HA-Tag-Lentivirus-Expression-System.html";
										break;
										
									case "LV022":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "G327":
									case "G328":
									case "LV098":
									case "LV099":
										$links = "/HA-Tag-Lentivirus-III-Expression-System.html";
										break;
										
									case "G300":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "G329":
									case "G330":
									case "LV098":
									case "LV099":
										$links = "/UbC-Promoter-Lentivirus-Expression-System.html";
										break;
										
									case "G305":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "G331":
									case "G332":
									case "LV098":
									case "LV099":
										$links = "/PGK-Promoter-Lentivirus-Expression-System.html";
										break;
										
									case "LV043":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV044":
									case "LV045":
									case "LV098":
									case "LV099":
										$links = "/EF1a-Promoter-Lentivirus-Expression-System.html";
										break;
										
									case "LV013":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV400":
									case "LV410":
									case "LV098":
									case "LV099":
										$links = "/Promoterless-Lentiviral-Vector.html";
										break;
										
									case "LV059":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV060":
									case "LV061":
									case "LV092":
									case "LV093":
									case "LV094":
									case "LV098":
									case "LV099":
										$links = "/Promoterless-GFP-Luc-Lentiviral-Vector.html";
										break;
										
									case "LV037":
									case "LV038":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV039":
									case "LV040":
									case "LV041":
									case "LV042":
									case "LV089":
									case "LV090":
									case "LV091":
									case "LV098":
									case "LV099":
										$links = "/Bicistronic-Tricistronic-Lentivirus-Lenti-X.html";
										break;
										
									case "LV014":
									case "LV016":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV012":
									case "LV300":
									case "LV301":
									case "LV310":
									case "LV311":
									case "LV098":
									case "LV099":
										$links = "/shrna-miRNA-Lentiviral-Sigma-Particles.html";
										break;
										
									case "LV076":
									case "LV079":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV077":
									case "LV080":
									case "LV078":
									case "LV081":
									case "LV098":
									case "LV099":
										$links = "/RFP-Lentivirus-RFP.html";
										break;
										
									case "LV031":
									case "LV032":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV033":
									case "LV034":
									case "LV035":
									case "LV036":
									case "LV098":
									case "LV099":
										$links = "/GFP-Lentivirus-GFP-Fusion.html";
										break;
										
									case "LV067":
									case "LV070":
									case "LV073":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV068":
									case "LV071":
									case "LV074":
									case "LV069":
									case "LV072":
									case "LV075":
										$links = "/GFP-Bicistronic-Lentivirus-Clon-tech.html";
										break;
										
									case "LV084":
									case "LV003":
									case "G074":
									case "LV010":
									case "LV011-a":
									case "LV085":
									case "LV086":
									case "LV098":
									case "LV099":
										$links = "/viralexp/lentivirus-rfp-coexpression-system.php?csn=14&ssn=3884&dsn=104784";
										break;
										
									case "LV006":
									case "LV007":
									case "LV027":
									case "LV028":
									case "LV046":
									case "LV051":
									case "LV052":
										$links = "/Reporter-Lentivirus-Luciferase.html";
										break;
										
									case "LV047":
									case "LV048":
									case "LV049":
									case "LV050":
										$links = "/HSV-TK-Lentivirus-GCV.html";
										break;//lentiviral expression systems
										
									case "LV003":
									case "LV006":
									case "LV007":
										$links = "/2nd-Genearation-Lentivirus-Packaging.html";
										break;
										
									case "LV053":
									case "LV006":
									case "LV007":
										$links = "/3rd-Generation-Lentivirus-Packaging.html";
										break;//lentivirus packaging systems
										
									case "G171":
									case "G172":
									case "G173":
										$links = "/Lentivirus-Purification-Concentration.html";
										break;
										
									case "LV999":
										$links = "/PEG-Lentivirus-Purification-Concentration.html";
										break;
										
									case "G698":
										$links = "/ViralPlus-Lentivirus-Transduction-Efficiency-Enhancer.html";
										break;
										
									case "G130":
										$links = "/Lentivirus-Storage-Buffer.html";
										break;
										
									case "LV900":
										$links = "/High-Titer-Lentivirus-Calculation.html";
										break;//lentivirus purification and titration
										
									case "E-514":
									case "E-510":
									case "E-511":
									case "E-512":
										$links = "/Retroviral-Vector.html";
										break;
										
									case "E-5145":
									case "E-510":
									case "E-511":
									case "E-513":
										$links = "/Retroviral-Infection.html";
										break;
										
									case "E-516":
									case "E-510":
									case "E-511":
									case "E-518":
										$links = "/Retroviral-HA-Fusion-Expression.html";
										break;
										
									case "E-517":
									case "E-510":
									case "E-511":
									case "E-519":
										$links = "/Retroviral-His-Fusion-Expression.html";
										break;
										
									case "E-514":
									case "E-515":
									case "E-516":
									case "E-517":
										$links = "/Retrovirus-Expression-Vectors.html";
										break;
										
									case "E-510":
									case "E-511":
									case "E-520":
									case "E-521":
									case "000194A":
									case "000195A":
									case "G036":
									case "G020":
										$links = "/Retrovirus-Packaging.html";
										break;
									
									case "LV998":
										$links = "/Ultra-Lentivirus-Purification-Concentration.html";
										break;
										
									case "MK001":
									case "MK002":
									case "MK003":
									case "MK004":
										$links = "/miRNA/expression/miRNA-Kit-Contents.php";
										break;
										
									case "LV587":
									case "LV588":
									case "LV589":
									case "LV090":
									case "LV091":
										$links = "/Lentiviral-Blank-Control-Vectors.html";
										break;
										
									default:
										$links="#";
								}
								
								if ($links == "/miRNA/expression/miRNA-Kit-Contents.php"){
									echo"	<td><a href='$links' target='_blank'>$prodname</a></td>
											<td align='center'>$quant</td>
											<td align='center'>$catno</td>
											<td align='right' class='price'>$$price.00</td>
											<td align='center'><input type='checkbox' name='grp[]' value='$catno' /></td>
										 </tr>";
								}else{
									echo"	<td><a href='$links'>$prodname</a></td>
											<td align='center'>$quant</td>
											<td align='center'>$catno</td>
											<td align='right' class='price'>$$price.00</td>
											<td align='center'><input type='checkbox' name='grp[]' value='$catno' /></td>
										 </tr>";
								}
							}
						}
					echo "</table>";
		  		?>
           </div>
           <div id = 'exp-add'>
              <input name='car' type='hidden' id='car' value='1'/>
              <input type="hidden" name="addsign" id="addsign" value='1' />
              <input name='csn' type='hidden' id='csn' value='<?php echo $csn;?>'/>
              <input name='ssn' type='hidden' id='ssn' value='<?php echo $ssn;?>'/>
              <input name='dsn' type='hidden' id='dsn' value='<?php echo $dsn;?>'/>
              <input id="expcart" name="expcart" type="submit" value="Add to Cart" />
            </div>
          </form>
        </div>
        <a name="cart"></a>
        <div id='cart'><a href='?cart=<?php echo ($cart+1)%2;?>&amp;csn=<?php echo $csn;?>&amp;ssn=<?php echo $ssn;?>&amp;catno=<?php echo $catno;?>#cart'><img id="carttab" src="../images/cart.png" border="0" /></a></div>
        <?php include('../includes/shoppingCart.php');?> 
      </div>
    </div>
  </div>
</div>
<?php include('../includes/footer.php');?>

<!-- Piwik --> 
<script type="text/javascript">
var pkBaseURL = (("https:" == document.location.protocol) ? "https://www.abmgood.com/piwik/" : "http://www.abmgood.com/piwik/");
document.write(unescape("%3Cscript src='" + pkBaseURL + "piwik.js' type='text/javascript'%3E%3C/script%3E"));
</script><script type="text/javascript">
try {
var piwikTracker = Piwik.getTracker(pkBaseURL + "piwik.php", 1);
piwikTracker.trackPageView();
piwikTracker.enableLinkTracking();
} catch( err ) {}
</script>
<noscript>
<p><img src="http://www.abmgood.com/piwik/piwik.php?idsite=1" style="border:0" alt="" /></p>
</noscript>
<!-- End Piwik Tag -->
</body>
</html>
